<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>animate</title>
    <link rel="stylesheet" href="../../css/common.css">
    <link rel="stylesheet" href="../../assets/lib/animate/animate.min.3.5.1.css">
    <style>
        #box {
            width: 200px;
            height: 200px;
            background-color: orange;
        }
    </style>
</head>

<body>
    <div id="box"> </div>
    <script src='../../js/common.js'></script>
    <script>
        $(function () {
            $('#box').addClass('animated shake');
            setTimeout(function () {
                $('#box').removeClass('shake');
            }, 3000);
        });

        // $('#box').click(() => {
        //     console.log($(this))
        // })

        $('#box').click(function () {
            console.log($(this))
            $(this).addClass('shake').removeClass('shake')
        })
    </script>
</body>

</html>